---
layout: default
---

<!-- Page Header -->
<header class="intro-header" style="background-image: url('{{ site.baseurl }}/{% if page.header-img %}{{ page.header-img }}{% else %}{{ site.header-img }}{% endif %}')">
	<div class="container">
		<div class="row">
			<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1 ">
				<div class="site-heading">
					<h1>{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}</h1>
					<!--<hr class="small">-->
					<span class="subheading">{{ page.description }}</span>
				</div>
			</div>
		</div>
	</div>
</header>

<!-- Main Content -->
<div class="container">
	<div class="row">
		{% if site.sidebar == false %}

			<!-- NO SIDEBAR -->
			<!-- PostList Container -->
			<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1 postlist-container">
				{{ content }}
			</div>
			<!-- Sidebar Container -->
			<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1 sidebar-container">

				<!-- Featured Tags -->
				{% if site.featured-tags %}
					<section>
						<!-- no hr -->
						<h5><a href="{{'/tags/' | prepend: site.baseurl }}">FEATURED TAGS</a></h5>
						<div class="tags">
							{% for tag in site.tags %}
								{% if tag[1].size > site.featured-condition-size %}
									<a href="{{ site.baseurl }}/tags/#{{ tag[0] }}" title="{{ tag[0] }}" rel="{{ tag[1].size }}">
										{{ tag[0] }}
									</a>
								{% endif %}
							{% endfor %}
						</div>
					</section>
				{% endif %}

				<!-- Friends Blog -->
				{% if site.friends %}
				<hr>
				<h5>FRIENDS</h5>
				<ul class="list-inline">
					{% for friend in site.friends %}
					<li><a href="{{friend.href}}">{{friend.title}}</a></li>
					{% endfor %}
				</ul>
				{% endif %}
			</div>

		{% else %}

		<!-- USE SIDEBAR -->
		<!-- PostList Container -->
		<div class="col-lg-8 col-lg-offset-1 col-md-8 col-md-offset-1 col-sm-12 col-xs-12 postlist-container">
			{{ content }}
		</div>
		<!-- Sidebar Container -->
		<div class="col-lg-3 col-lg-offset-0 col-md-3 col-md-offset-0 col-sm-12 col-xs-12 sidebar-container">

			<!-- Featured Tags -->
			{% if site.featured-tags %}
				<section>
					<hr class="hidden-sm hidden-xs">
					<h5><a href="{{'/tags/' | prepend: site.baseurl }}">FEATURED TAGS</a></h5>
					<div class="tags">
						{% for tag in site.tags %}
							{% if tag[1].size > site.featured-condition-size %}
								<a href="{{ site.baseurl }}/tags/#{{ tag[0] }}" title="{{ tag[0] }}" rel="{{ tag[1].size }}">
									{{ tag[0] }}
								</a>
							{% endif %}
						{% endfor %}
					</div>
				</section>
			{% endif %}

				<!-- Short About -->
				<section class="visible-md visible-lg">
					<hr>
					<h5><a href="{{'/about/' | prepend: site.baseurl }}">ABOUT ME</a></h5>
					<div class="short-about">
						{% if site.sidebar-avatar %}
							<a href="{{ site.baseurl }}/about">
								<img src="{{site.sidebar-avatar}}" />
							</a>
						{% endif %}
						{% if site.sidebar-about-description %}
							<p>{{site.sidebar-about-description}}</p>
						{% endif %}
						<!-- SNS Link -->
						<ul class="list-inline">

							<!-- add Github -->
							{% if site.github_username %}
								<li>
									<a target="_blank" href="https://github.com/{{ site.github_username }}">
										<span class="fa-stack fa-lg">
											<i class="fa fa-circle fa-stack-2x"></i>
											<i class="fa fa-github fa-stack-1x fa-inverse"></i>
										</span>
									</a>
								</li>
							{% endif %}
							
							<!-- add csdn -->
							{% if site.csdn_username %}
								<li>
									<a target="_blank" href="https://blog.csdn.net/{{ site.csdn_username }}">
										<span class="fa-stack fa-lg">
											<i class="fa fa-circle fa-stack-2x"></i>
											<i class="fa fa-stack-1x fa-inverse">C</i>
										</span>
									</a>
								</li>
							{% endif %}
							
							<!-- add 简书 -->
							{% if site.jianshu_username %}
								<li>
									<a target="_blank" href="https://www.jianshu.com/u/{{ site.jianshu_username }}">
										<span class="fa-stack fa-lg">
											<i class="fa fa-circle fa-stack-2x"></i>
											<i class="fa fa-stack-1x fa-inverse">简</i>
										</span>
									</a>
								</li>
							{% endif %}

						</ul>
						{% if site.email %}
							<p>✉️ {{site.email}}</p>
						{% endif %}
					</div>
				</section>
				<!-- Friends Blog -->
				{% if site.friends %}
					<hr>
					<h5>FRIENDS</h5>
					<ul class="list-inline">
						{% for friend in site.friends %}
							<li>
								<a href="{{friend.href}}">{{friend.title}}</a>
							</li>
						{% endfor %}
					</ul>
				{% endif %}
			</div>
			
		{% endif %}
	</div>
</div>
